package com.example.lotapp.utils.json;

import java.math.BigDecimal;
import java.math.BigInteger;
import java.util.Date;
import java.util.List;

import com.example.lotapp.AppContext;
import com.example.lotapp.utils.FileUtils;


public class JsonParserTest {
	
	public static void test() {
		String json = FileUtils.getAssetsFileContent(AppContext.getInstance(), "test.json");
		Tmp tmp = Json.parseObject(json, Tmp.class);
		String string = tmp.toString();
		int a = 0;
		a += 0;
	}

	static class Tmp {
		static class tt {
			@JsonField(name="boolean")
			public boolean t_b;
		};
		
		@JsonField(name="array")
		public List<tt> t_array;
	
		@JsonField(name="boolean_true")
		public boolean t_true;
		
		@JsonField(name="boolean_false")
		public boolean t_false;
		
		@JsonField(name="long")
		public long 	t_long;
		
		@JsonField(name="int")
		public int t_int;
		
		@JsonField(name="float")
		public float t_float;
		
		@JsonField(name="double") 
		public double t_double;
		
		@JsonField(name="string")
		public String t_tring;
		
		@JsonField(name="bigInt")
		public BigInteger t_bigInteger;
		
		@JsonField(name="bigDecimal")
		public BigDecimal t_bigDecimal;
		
		@JsonField(name="date", format="yyyy-MM-dd HH:mm:ss")
		public Date t_date;
	}
}
